<%@ page language="java" isELIgnored="false" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<!DOCTYPE html>
<%@ include file="/WEB-INF/jsp/ResourceGlobal.jsp"%>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<html>

<head>
<!-- 这里引入导航信息header.tpl -->
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title name="titleName">档案管理</title>
<style type="text/css">
	.panel-input {
		width: 70%;
		float:left;
		margin: 0px 10px;
	}
	
	.float-left{
		float:left;
	}
</style>
<script type="text/javascript">
	var productPath = '<%=context%>' +'business/product/';
	var archivePath = '<%=context%>' +'business/archiveManagement/';
	//默认加载
	$(function(){
		//把访问路径传到js
		setPathPrefix(productPath,archivePath);
	});
</script>
<script type="text/javascript" src="<%=context%>resources/modules/system/common/widget.js"></script>
<script type="text/javascript" src="<%=context%>resources/modules/system/common/multi.upload.js"></script>
<script type="text/javascript" src="<%=context%>resources/modules/business/archiveManagement/archiveManagement.create.js?r=<%=Math.random()%>"></script>
</head>

<body class="sub-page">

	<jsp:include page="/WEB-INF/jsp/system/index/homeHead.jsp">
		<jsp:param name="currentActive" value="cpyy" />
	</jsp:include>
		
	<div class="location">
		<i class="fas fa-home"></i>
		<p>您现在的位置：主页</p>
		<p class="current">&gt;产品运营</p>
		<p class="current">&gt;档案管理</p>
		<p class="current">&gt;<span name="titleName">新增</span></p>
	</div>
	<div class="container">
		<!-- 档案管理新建模态窗 -->
		<form id="archiveAddForm" role="form" class="form-horizontal" method="post" action="<%=context%>business/archiveManagement/saveArchive.do">
			<!-- 如果将表单禁用，就给fieldset添加disabled属性 -->
			<fieldset>
	
				<div class="page-content">
					<div class="page-header">
						<h4 class="page-title" name="titleName">档案管理</h4>
						<input type="hidden" id="actionType" name="actionType" value="${actionType }">
						<input type="hidden" id="prjCode" name="prjCode" value="${attach.prjCode }"/>
						<input type="hidden" id="oldPrjCode" name="oldPrjCode" value="${attach.prjCode }"/>
					</div>
					<div class="page-body">
						<div class="panel-input">
							<div class="form-group">
								<label class="col-sm-2 control-label">产品简称<span class="text-danger">*</span></label>
								<div class="col-sm-10 form-inner">
									<input type="text" placeholder="产品简称" class="form-control" id="prjsname" name="prjsname" value="${attach.prjSName }" readonly="readonly"/>
								</div>
							</div>
						</div>
						
						<button type="button" class="btn btn-primary btn-w-xs float-left " onclick="ARCHIVE.selectProject();">选择产品</button>
						<!-- 附件展示上传 -->
						<jsp:include page="../../system/sys/attach/attachView.jsp">
							<jsp:param name="attachList" value="${attachList}"/>
							<jsp:param name="resourceId" value=""/>
							<jsp:param name="module" value="ArchiveAddView" />
							<jsp:param name="hasPermission" value="archiveManagementAdd" />
							<jsp:param name="resourceSign" value="ARCHIVE_ADD"/>
							<jsp:param name="hidAttIdField"  value="{{attId}}"/>
							<jsp:param name="hasExpandField" value='[{"fieldKey":"archiveType","fieldName":"档案类型"}]'/>
							<jsp:param name="hasExpandList" value="[${expandList}]"/>
							<jsp:param name="isOperable" value='{"isOperable":"${"detail" eq actionType ? false : true}"}'/>
						</jsp:include>
					</div>
					<div class="page-footer">
						<button type="button" class="btn btn-primary btn-save btn-loading btn-w-xs" id="commitBtn" name="commitBtn" data-loading-text="<i class='ico-loading'></i>" onclick="${'add' eq actionType?'ARCHIVE.addArchive()':'ARCHIVE.updateArchive()'}">提交</button>
						<button type="button" class="btn btn-link btn-w-xs" id="cancelBtn" name="cancelBtn" onclick="window.close();">取消</button>
					</div>
				</div>
			</fieldset>
		</form>
	</div>
</body>